//
//  SelfSizeTool.m
//  10-CellSelf-Size
//
//  Created by GivenBmli on 16/7/27.
//  Copyright © 2016年 GivenBmli. All rights reserved.
//

#import "SelfSizeTool.h"

@implementation SelfSizeTool
+ (CGFloat)selfSiezeHeightWithSting:(NSString *)sting width:(CGFloat )width font:(UIFont *)font {
    CGRect newRect = [sting boundingRectWithSize:CGSizeMake(width, CGFLOAT_MAX) options:NSStringDrawingUsesLineFragmentOrigin attributes:@{NSFontAttributeName:font} context:nil];
    return newRect.size.height;
}
@end
